package org.boz.dial;

public abstract class LispObject {
	public abstract String toString();

	public Object toObject() {
		return null;
	}

	public LispObject car() {
		throw new RuntimeException("car is invalid on: " + this);
	}

	public LispObject cdr() {
		return LispPrimitives.nil;
	}

	public abstract LispObject eval(LispObject env);

	public LispObject apply(LispObject vals, LispObject env) {
		throw new RuntimeException("bad object for apply: " + this);
	}
}
